#ifndef CONFIG_H
#define CONFIG_H

#include "inspector.h"
#include "redismodule.h"

#define DEFAULT_INSPECTOR_TIMER_INTERVAL (60 * 60 * 1000)      // 每轮扫描的间隔, ms
#define DEFAULT_INSPECTOR_SCAN_TICK 1000                       // 每次scan运行间隔 ms
#define DEFAULT_INSPECTOR_SCAN_COUNT 1000                      // 每次scan count
#define DEFAULT_INSPECTOR_ITEMS_THRESHOLD 10000                // 集合类型的元素个数
#define DEFAULT_INSPECTOR_MEMORY_THRESHOLD (10 * 1024 * 1024)  // 10M
#define DEFAULT_INSPECTOR_TTL_THRESHOLD (604800 * 1000)        // 7 days, ms

int load_config(RedisModuleCtx *ctx, const char *path, TaskConfig *config);
int flush_config(RedisModuleCtx *ctx, const char *path, const TaskConfig *config);

#endif
